#!/usr/bin/env python
# -*- coding: UTF-8 -*-

# Magpie - an open source discussion forum system.
#
# Copyright (C) 2009 The Magpie Team
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>.

import os

ROOT_PATH = os.path.dirname(__file__)

APPEND_SLASH = True

ROOT_URLCONF = 'ajiaojr.magpie.urls'

INSTALLED_APPS = (
  'ajiaojr.commons.django',
)

TEMPLATE_CONTEXT_PROCESSORS = (
  'django.core.context_processors.request',
  'django.core.context_processors.i18n',
)

MIDDLEWARE_CLASSES = (
  'django.middleware.common.CommonMiddleware',
  'django.middleware.locale.LocaleMiddleware',
  'django.middleware.doc.XViewMiddleware',
  'ajiaojr.commons.django.middleware.MobileUserAgentDetectorMiddleware',
  'ajiaojr.magpie.middleware.AddUserToRequestMiddleware',
)

LOCALE_PATHS = (
  os.path.join(ROOT_PATH, 'django-i18n'),
)

TEMPLATE_DIRS = (
  ROOT_PATH + '/templates',
)

USE_I18N = True
